/**
 * 
 */
package cn.ivicar.passport.controller.utils;

import org.apache.commons.codec.digest.DigestUtils;

/**
 * @Author: liurunbin
 * @Description:手机号工具类
 * @Date: Created in 2017/5/22
 */
public class PassportUtil {

	/*
	校验手机号是否合法
	 */
	public static boolean validateMobile(String mobile) {
		String reg = "^1[3|4|5|7|8]\\d{9}$";
		return mobile.matches(reg);
	}

	public static String doSalt(String password) {
		String seed = "**.deng";
		String md5 = DigestUtils.md5Hex(password + seed);
		return md5;
	}
}
